using WeatherApp.Models;

namespace WeatherApp.Services
{
    public interface IDataService
    {
        // 天气记录相关
        Task<WeatherRecord> SaveWeatherRecordAsync(WeatherInfo weatherInfo);
        Task<List<WeatherRecord>> GetWeatherHistoryAsync(string city, int days = 7);
        Task<List<WeatherRecord>> GetRecentWeatherRecordsAsync(int count = 10);

        // 用户设置相关
        Task<UserSettings> GetUserSettingsAsync(string userId);
        Task<UserSettings> SaveUserSettingsAsync(string userId, UserSettingsDto settings);
        Task<bool> DeleteUserSettingsAsync(string userId);

        // 搜索历史相关
        Task<List<SearchHistory>> GetSearchHistoryAsync(string userId, int count = 10);
        Task<SearchHistory> AddSearchHistoryAsync(string userId, string cityName);
        Task<bool> ClearSearchHistoryAsync(string userId);

        // 收藏城市相关
        Task<List<FavoriteCity>> GetFavoriteCitiesAsync(string userId);
        Task<FavoriteCity> AddFavoriteCityAsync(string userId, string cityName);
        Task<bool> RemoveFavoriteCityAsync(string userId, string cityName);
        Task<bool> IsFavoriteCityAsync(string userId, string cityName);
    }
} 